<template>
  <el-form :model="detailForm" class="elForm">
    <el-card class="box-card" shadow="never">
      <div slot="header">
        <span>车辆信息</span>
      </div>
      <el-row :gutter="20">
        <el-col :span="8">
          <el-form-item label="车架号：">
            <span>{{ detailForm.vinNo }}</span>
          </el-form-item>
        </el-col>
        <el-col :span="8">
          <el-form-item label="品牌/车型/车系：">
            <span>{{
                `${detailForm.brandName ? detailForm.brandName : ""}${
                    detailForm.seriesName ? detailForm.seriesName + "/" : ""
                }${detailForm.modelName ? detailForm.modelName + "/" : ""}`
              }}</span>
          </el-form-item>
        </el-col>
        <el-col :span="8">
          <el-form-item label="车辆产权：">
            <span>{{ detailForm.propertyRightName }}</span>
          </el-form-item>
        </el-col>
        <el-col :span="8">
          <el-form-item label="车辆归属：">
            <span>{{ detailForm.ascription }}</span>
          </el-form-item>
        </el-col>
        <el-col :span="8">
          <el-form-item label="车辆运营：">
            <span>{{ detailForm.operationsName }}</span>
          </el-form-item>
        </el-col>
        <el-col :span="8">
          <el-form-item label="车辆大区：">
            <span v-if="detailForm.region">{{detailForm.region}} </span>

          </el-form-item>
        </el-col>
        <el-col :span="8">
          <el-form-item label="被保险人：">
            <span>{{ detailForm.jqxInsuredName }}</span>
          </el-form-item>
        </el-col>
        <el-col :span="8">
          <el-form-item label="行驶证车主：">
            <span>{{ detailForm.ownerName }}</span>
          </el-form-item>

        </el-col>

        <el-col :span="8">
          <el-form-item label="租车方名称：">
            <span>{{ detailForm.leaseeName }}</span>
          </el-form-item>
        </el-col>
        <el-col :span="8">
          <el-form-item label="车牌号：">
            <span>{{ detailForm.carNo }}</span>
          </el-form-item>
        </el-col>
<!--        <el-col :span="8">
          <el-form-item label="品牌：">
            <span>{{ detailForm.brandName }}</span>
          </el-form-item>
        </el-col>

        <el-col :span="8">
          <el-form-item label="厂牌型号：">
            <span>{{ detailForm.brandName }}</span>
          </el-form-item>
        </el-col>-->
        <el-col :span="8">
          <el-form-item label="座位数：">
            <span>{{ detailForm.seatNum }}</span>
          </el-form-item>
        </el-col>
        <el-col :span="8">
          <el-form-item label="发动机号码：">
            <span>{{ detailForm.engineNo }}</span>
          </el-form-item>

        </el-col>

        <el-col :span="8">
          <el-form-item label="排量：">
            <span>{{ detailForm.liter }}</span>
          </el-form-item>
        </el-col>
        <el-col :span="8">
          <el-form-item label="车辆开票价：">
            <span>{{ detailForm.purchasePrice }}</span>
          </el-form-item>
        </el-col>
        <el-col :span="8">
          <el-form-item label="车辆初次登记日期：">
            <span>{{ detailForm.registerTime }}</span>
          </el-form-item>

        </el-col>

        <el-col :span="8">
          <el-form-item label="燃油类型：">
            <span>{{ detailForm.fuelTypeStr }}</span>
          </el-form-item>
        </el-col>
<!--        <el-col :span="8">
          <el-form-item label="保险性质：">
            <span>{{ detailForm.insuranceType }}</span>
          </el-form-item>
        </el-col>-->
<!--        <el-col :span="8">
          <el-form-item label="车辆初次登记日期：">
            <span>{{ detailForm.registerTime }}</span>
          </el-form-item>

        </el-col>-->
      </el-row>

    </el-card>
  </el-form>
</template>

<script>
export default {
  name: 'carInfo',
  props: {
    value: {
      type: Object,
      default: {}
    },

  },
  computed: {
    detailForm: {
      get() {
        let that = this
        const proxy = new Proxy(that.value, {
          get(target, key, value) {
            return Reflect.get(target, key)
          },
          set(target, key, value) {
            that.$emit('input', {...target, [key]: value})
            return true
          }
        })
        return proxy
      }
    },
    labelPosition() {
      if (this.isEdit) {
        return 'top'
      } else {
        return 'right'
      }

    }
  },
  watch: {},
  data() {
    return {
      isEdit: false
    };
  },
  created() {

  },
  mounted() {
  },
  methods: {},
};
</script>

<style lang="scss" scoped>
@import "@/styles/cwgd/formScss.scss";
</style>


